import { selList, del, selById, add, listAllTableData, edit, getCity } from '@/services/plannedFollowUpApi';

export default {
    namespace: 'plannedFollowUp',

    state: {

    },

    effects: {
        /**
        * 分页
        * @param payload
        * @param call
        * @param put
        * @returns {Generator<*, *, *>}
        */
        *selList({ payload }, { call, put }) {
            const response = yield call(selList, payload);
            return response;
        },

        /**
      * 删除
      * */
        *del({ payload }, { call, put }) {
            const response = yield call(del, payload);
            return response;
        },

        /**
     * 详情
    * */
        *selById({ payload }, { call, put }) {
            const response = yield call(selById, payload);
            return response;
        },

        /**
      * 添加
      * */
        *add({ payload }, { call, put }) {
            const response = yield call(add, payload);
            return response;
        },

        /**
     * id
     * */
        *listAllTableData({ payload }, { call, put }) {
            const response = yield call(listAllTableData, payload);
            return response;
        },


        /**
     * 编辑
     * */
        *edit({ payload }, { call, put }) {
            const response = yield call(edit, payload);
            return response;
        },


        /**
        * 省……乡
        * */
        *getCity({ payload }, { call, put }) {
            const response = yield call(getCity, payload);
            return response;
        },
    },

    reducers: {


    },
};

